CC = gcc
CFLAGS =

BIN = bin
SRC = src
OBJ = obj

PROGRAM_NAME = smoothFilter
IMG = in.ppm

all: smoothFilter.o compile

compile:
	@$(CC) $(OBJ)/$(PROGRAM_NAME).o -o $(BIN)/$(PROGRAM_NAME)
	@echo compilation completed

smoothFilter.o:
	@$(CC) -c $(SRC)/$(PROGRAM_NAME).c $(CFLAGS) -o $(OBJ)/$(PROGRAM_NAME).o
	@echo smoothFilter.o compiled
	
run:
	@echo running...
	@./$(BIN)/$(PROGRAM_NAME) $(IMG)
	@echo running successful

clear:
	@echo cleaning project
	@rm $(OBJ)/*.o $(BIN)/*
